﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using QuartzScheduler;
using System.Data;
using Quartz;

namespace ServiceJob.Jobs
{
    class IJobDeleteExpired:IJob
    {
        public void Execute(Quartz.JobExecutionContext context)
        {
            try
            {
                string sql = "delete from [T_RunJob] where endDateTime<='" + DateTime.Now.ToLocalTime() + "'";
                SqlServerClass ssc = new SqlServerClass();
                ssc.MySqlExcute(sql);
            }
            catch (Exception ex)
            {
                throw;
            }
        }
    }
}
